#ifndef FEATUREMAIN_H
#define FEATUREMAIN_H

#include <QMainWindow>
#include <QAbstractItemModel>

namespace Ui {
class FeatureMain;
}

const static int NOT_STARTED=0;
const static int WORKING=1;
const static int FINISHED=2;
const static int DISCARD=3;

class FeatureMain : public QMainWindow{
    Q_OBJECT

public:
    explicit FeatureMain(QWidget *parent = 0);
    ~FeatureMain();
public slots:
    void addFeature();
    void editFeature();
    void delFeature();
    void saveFeature();
    void cancelEditFeature();
    void searchFeature();
    void editPrevFeature();
    void editNextFeature();
    void itemActivated(int index);
private slots:
    void setInputFieldEnable(bool enable);
    void clearInputField();
protected:
    void closeEvent(QCloseEvent *);
    void loadFeatures();
private:
    Ui::FeatureMain *ui;
};

#endif // FEATUREMAIN_H
